#pragma once
#include "GameXML.h"
#include "../globalconfig/ResPathConfig.h"
#include "tinyxml2/tinyxml2.h"
#include "cocos2d.h"
USING_NS_CC;
using namespace tinyxml2;

class GameConfigXML
{
public:

	static GameConfigXML* inst()
	{
		static GameConfigXML* instance = new GameConfigXML();
		return instance;
	}

	~GameConfigXML(void);

	void getData(std::string id, char* data);
	void getData(std::string id, int& data);

private:
		GameConfigXML(void);

		void loadFile();

		void initXMLData();

private:
	
	tinyxml2::XMLDocument							_doc;
	std::map<std::string, std::string>			_dataList;
};

